package com.ruoyi.system.dto;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.time.LocalDateTime;
import java.util.List;

/**
 * 项目进度DTO
 */
@Data
@ApiModel("项目进度DTO")
public class ProjectProgressDTO {

    @ApiModelProperty("项目ID")
    private Long projectId;

    @ApiModelProperty("项目类型")
    private String projectType;

    @ApiModelProperty("模板ID")
    private Long templateId;

    @ApiModelProperty("模板名称")
    private String templateName;

    @ApiModelProperty("当前阶段ID")
    private Long currentStageId;

    @ApiModelProperty("当前阶段名称")
    private String currentStageName;

    @ApiModelProperty("当前阶段顺序")
    private Integer currentStageOrder;

    @ApiModelProperty("进度百分比")
    private Integer progressPercentage;

    @ApiModelProperty("阶段列表")
    private List<StageProgressDTO> stageList;

    @ApiModelProperty("创建时间")
    private LocalDateTime createTime;

    @ApiModelProperty("更新时间")
    private LocalDateTime updateTime;

    /**
     * 阶段进度DTO
     */
    @Data
    @ApiModel("阶段进度DTO")
    public static class StageProgressDTO {
        @ApiModelProperty("阶段ID")
        private Long stageId;

        @ApiModelProperty("阶段名称")
        private String stageName;

        @ApiModelProperty("阶段顺序")
        private Integer stageOrder;

        @ApiModelProperty("是否当前阶段")
        private Boolean isCurrentStage;

        @ApiModelProperty("是否已完成")
        private Boolean isCompleted;

        @ApiModelProperty("完成备注")
        private String completionRemark;

        @ApiModelProperty("完成日期")
        private LocalDateTime completionDate;

        @ApiModelProperty("完成类型")
        private String completionType;

        @ApiModelProperty("备注规则")
        private String remarkRule;

        @ApiModelProperty("完成标识规则")
        private String completionRule;

        @ApiModelProperty("完成日期规则")
        private String completionDateRule;

        @ApiModelProperty("关联H5模块")
        private String associatedH5Module;

        @ApiModelProperty("状态映射")
        private String statusMapping;
    }
}
